﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading;

namespace CompositionPlugin
{
    public class ModuleDefinition
    {
        public ModuleDefinition(Lazy<IModule, IModuleMetadata> lazyObject)
        {
            if (lazyObject == null)
                throw new ArgumentNullException("lazyObject");
            this._lazyObject = lazyObject;
        }
        /// <summary>
        /// Module
        /// </summary>
        internal IModule Value
        {
            get
            {
                return this._lazyObject.Value;
            }
        }

        public IModuleMetadata Metadata
        {
            get
            {
                return this._lazyObject.Metadata;
            }
        }

        #region private

        private Lazy<IModule, IModuleMetadata> _lazyObject;

        #endregion
    }
}
